<script setup lang="ts">
import {ref} from "vue";

defineProps(['car', 'sendT'])
let t = ref('玩具')
</script>

<template>
<h2>子组件收到父组件的值:{{car}}</h2>
  <button @click="sendT(t)">子组件给父组件的</button>

</template>

<style scoped>

</style>